<template>
	<view>
		<view class="text-center p-10 flex flex-column">
			<text class="fs-18 fw-600">{{info?.name}}</text>
			<view class="text-right mt-10">
				<text class="fs-12 text-grey-1">{{info?.page_view}}次浏览 {{info?.create_at}}</text>
			</view>
		</view>
		<view class="p-10 ">
			<mp-html :content="info?.content" selectable class="text-wrap content"></mp-html>
		</view>
	</view>
</template>

<script setup>
	import { ref } from 'vue'
	import { onLoad } from '@dcloudio/uni-app'
	import { $http } from '@/utils/index';
	const info = ref()
	onLoad((option) => {
		getTag(option.id)
	})
	const getTag = ((id) => {
		$http.get('Article/getDetail', { id: id }).then(res => {
			info.value = res.data
		})

	})
</script>

<style scoped>
	page {
		background-color: #fff;
	}

	.content ._img {
		max-width: 100%;
		white-space: wrap;
	}
</style>